<p>
   旧密码：<input type='password' name='old_pas'/>
</p>
<p>
   新密码：<input type='password' name='new_pas'/>
</p>
<p>
    &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<input type='button' name='submit' value='提交' style='width:80px;height:30px;background:#ff3300;border:0px;text-align:center;color:white;'/>
</p>
<script src='/js/jquery.js'></script>
<script src='/js/layer.js'></script>
<script>
     $('input[name=submit]').click(function(){
	    $.ajax({
		    url:'/admin.php/index/pass',
			data:{'old_pas':$('input[name=old_pas]').val(),'new_pas':$('input[name=new_pas]').val()},
			dataType:'json',
			type:'post',
			success:function(res){
			   if(res.status=='ok'){
			      layer.msg('你已修改密码！请重新登入！',{time:1600,icon:6});
				  setTimeout(function(){
				     parent.location.reload();
				  },1600);
			   }else{
			      layer.msg(res.error,{time:1600,icon:7});
				  setTimeout(function(){
				     parent.layer.closeAll();
				  },1600);
			   }
			}
		});
	 });
</script>
<style>
    p input[name=old_pas],p input[name=new_pas]{
	     border:1px solid #ccc;
		 width:150px;
         height:25px;
	 }
</style>